//
//  HSYBaseTableViewCell.m
//  高仿暴走斗图
//
//  Created by huangsongyao on 16/3/4.
//  Copyright © 2016年 huangsongyao. All rights reserved.
//

#import "HSYBaseTableViewCell.h"

@implementation HSYBaseTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier frame:(CGRect)frame {
    
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        
    }
    return self;
}

- (void)updateConstraint
{
    [self needsUpdateConstraints];
    [self updateConstraintsIfNeeded];
}

- (void)updateConstraintsForLastView:(UIView *)view asOffset:(CGFloat)offset
{
    [self.contentView mas_updateConstraints:^(MASConstraintMaker *make) {
        make.left.equalTo(self.mas_left);
        make.top.equalTo(self.mas_top);
        make.width.equalTo(@(IPHONE_WIDTH));
        make.bottom.equalTo(view.mas_bottom).offset(fabs(offset));
    }];
}

@end
